<template>
  <div class="nocontent">
    <div class="nocontent_content" v-if="type === 1">
      <h1>
        {{ $t("lang.欢迎新的你", { g: $store.state.user.nickName }) }}
      </h1>
      <p>{{ $t("lang.没有动态就发布一个动态") }}</p>
      <slot name="noContentSlot"></slot>
    </div>
    <div class="nocontent_content" v-else>
      <span class="nocontent_content_tip">{{ $t("lang.暂无") }}</span>
    </div>
  </div>
</template>
<script>
export default {
  name: "NoContent",
  props: {
    type: {
      type: Number,
      default() {
        return 1;
      },
    },
  },
  data() {
    return {};
  },
};
</script>
<style lang="less">
@base: 23.44rem;
.nocontent {
  background-color: #fff;
  .nocontent_content {
    padding: 10 / @base 20 / @base;
    h1 {
      font-size: 20 / @base;
      padding: 10 / @base 0;
    }
    p {
      font-size: 14 / @base;
      padding: 10 / @base 0;
    }
    span {
      &.nocontent_content_tip {
        display: block;
        padding: 20 / @base 0;
        color: #ccc;
      }
    }
  }
}
</style>
